Learn R Programming

memisc (version 0.99.31.8)

negative match: Negative Match

Description

%nin% is a convenience operator: x %nin% table is equivalent to !(x %in% table).

Usage

x %nin% table

Value

A logical vector

Arguments

x

the values to be matched

table

a values to be match against

Examples

Run this code
x <- sample(1:6,12,replace=TRUE)
x %in% 1:3
x %nin% 1:3

Run the code above in your browser using DataLab